public class func_max {
    public static int max2(int n1,int n2){
        return n1>n2?n1:n2;
    }
    public static double max2(double n1,double n2,double n3){
        double max= n1>n2?n1:n2;
        if(max<n3){
            max=n3;
        }
        return max;
    }
    public static int max3(int n1,int n2,int n3){
        return max2(max2(n1,n2),max2(n2,n3));
    }
    public static void main(String[] args) {
        System.out.println(max2(1.2,2.5,3.6));
        System.out.println(max2(1,2));
    }
}
